Modern retail and distribution enterprises face persistent challenges in coordinating real-time stock visibility, order lifecycle management, and inter-branch inventory transfers across geographically dispersed locations. Conventional inventory systems often suffer from monolithic architectures that hinder continuous delivery, limit horizontal scalability, and introduce prolonged downtime during deployments. This paper presents the design, implementation, and evaluation of a cloud-native, multi-branch inventory management platform that addresses these limitations through an asynchronous RESTful API backend built with Fast API and SQL Alchemy on Python 3.12, a reactive single-page application frontend developed with React and TypeScript, and a PostgreSQL relational database managed via Alembic schema migrations. The proposed system incorporates a role-based access control model distinguishing ADMIN, MANAGER, and STAFF privileges, real-time inventory notifications delivered over WebSocket connections, automated low-stock alerting, and cross-branch stock-transfer workflows with full audit trail persistence. Deployment reliability is achieved through an AWS-integrated CI/CD pipeline comprising AWS Code Commit, Code Build, and Code Pipeline, culminating in a zero-downtime blue-green deployment strategy on AWS Elastic Beanstalk. Experimental results demonstrate sub-100ms median API latency under simulated concurrent loads, a deployment rollout time of under three minutes, and zero production downtime during environment switchovers. The system\'s modular architecture and serverless-adjacent hosting model provide a reproducible, cost-effective blueprint for scalable inventory management in cloud-first organizations.
Introduction
Cloud computing has transformed enterprise application development by enabling scalable, accessible, and distributed systems. Inventory management systems, which traditionally depended on local servers and desktop applications, now require support for mobile users, multiple warehouses, real-time analytics, and continuous availability.
However, many existing inventory platforms still lack advanced enterprise capabilities such as:
Zero-downtime deployment.
Role-based access control.
Real-time event communication.
Cloud-native scalability.
The proposed work develops a cloud-native inventory management system that integrates an asynchronous backend, modern frontend, managed database, real-time communication, and automated deployment practices.
Research Contributions
The paper presents:
A full-stack cloud architecture combining:
FastAPI asynchronous backend.
React TypeScript frontend.
PostgreSQL database.
AWS cloud deployment.
A three-level role-based access control system:
ADMIN: Full access across all branches.
MANAGER: Branch-level management and transfer operations.
STAFF: Limited stock receiving operations.
A blue-green deployment strategy using AWS Elastic Beanstalk to achieve zero-downtime releases.
Performance evaluation through load testing and comparison with existing inventory solutions.
Literature Review Summary
Cloud-Native Architecture
Modern cloud applications use microservices, asynchronous communication, and independent deployment models. While these approaches improve scalability, many systems do not specifically address inventory challenges such as stock consistency and branch isolation.
Continuous Delivery and Deployment
Continuous delivery improves software reliability by automating deployment processes. Blue-green deployment maintains two identical environments and switches traffic between them, enabling:
No service interruption.
Fast rollback.
Safer releases.
Backend Technologies
The system uses:
FastAPI for high-performance API development.
SQLAlchemy Async for non-blocking database operations.
PostgreSQL for reliable relational storage.
Real-Time Communication
Traditional inventory systems often rely on periodic data polling. WebSocket-based communication enables instant updates, reducing delays in warehouse operations and improving coordination between branches.
Role-Based Access Control
RBAC improves security by assigning permissions based on user roles instead of individual users. The proposed system applies branch-level access restrictions to prevent unauthorized operations.
Infrastructure Automation
Cloud automation tools such as AWS CodePipeline and CodeBuild reduce deployment errors and enable repeatable CI/CD workflows.
Research Gap
Existing inventory platforms commonly lack:
Real-time stock updates.
Strong audit trails.
Cloud-native deployment approaches.
Integrated role-based multi-branch management.
The proposed system addresses these limitations.
Proposed Methodology
Data Model
The system uses a relational database design with major entities:
User
Branch
Product
Inventory
Stock Transaction
Order
Order Item
Key features:
Unique inventory record for each product and branch.
UUID-based identifiers.
Transaction-based stock updates for consistency.
Role-Based Access Model
Three user roles are implemented:
ADMIN
Complete access to all branches.
Full operational control.
MANAGER
Controls assigned branch inventory.
Can initiate outbound transfers.
STAFF
Limited to receiving stock.
Cannot perform outbound transactions.
Access control is enforced at the API level before database operations.
CI/CD Pipeline
The automated deployment process includes:
Code commit.
AWS CodePipeline trigger.
CodeBuild execution.
Frontend compilation.
Backend packaging.
Deployment to Elastic Beanstalk.
The system packages backend and frontend together into one deployable artifact.
Blue-Green Deployment
Two identical environments are maintained:
Blue environment: Current production version.
Green environment: New release version.
Deployment process:
New version is deployed to inactive environment.
Automated health checks verify readiness.
DNS CNAME switching transfers traffic.
Rollback is performed by switching back.
This enables zero-downtime releases.
System Design
The architecture consists of four layers:
1. Presentation Layer
React Single Page Application.
TypeScript-based frontend.
Real-time UI updates.
2. API Layer
FastAPI backend.
JWT authentication.
REST APIs.
WebSocket support.
3. Database Layer
PostgreSQL database.
SQLAlchemy asynchronous ORM.
Inventory schema isolation.
4. DevOps Layer
AWS CodePipeline.
AWS CodeBuild.
Elastic Beanstalk blue-green environments.
Implementation Summary
Backend
Developed using:
Python 3.12.
FastAPI.
SQLAlchemy 2.0.
PostgreSQL async driver.
JWT authentication.
Alembic migrations.
Gunicorn/Uvicorn deployment.
Frontend
Developed using:
React 18.
TypeScript.
Vite.
Tailwind CSS.
Features:
API integration.
Real-time WebSocket updates.
Optimistic UI changes.
Cloud Infrastructure
AWS services provide:
Automated builds.
Environment management.
Secure configuration handling.
Scalable deployment.
Results and Performance
Performance testing was conducted using load testing tools.
Key results:
Inventory API response:
42 ms at 50 users.
87 ms at 200 users.
Stock movement response:
51 ms at 50 users.
112 ms at 200 users.
WebSocket updates:
Less than 8 ms latency.
Deployment:
Blue-green switch completed in about 2 minutes 47 seconds.
Rollback completed in under 10 seconds.
The system achieved:
Real-time notifications.
Multi-branch access control.
Zero-downtime deployment.
Cloud-native CI/CD.
Conclusion
This paper has presented the design, implementation, and quantitative evaluation of a cloud-native multi-branch inventory management platform. The system achieves sub-100ms API latency under 200 concurrent users, sub-3-minute zero-downtime blue-green deployments, and sub-10-second rollbacks. A three-tier RBAC model ensures operational segregation across ADMIN, MANAGER, and STAFF roles, while a WebSocket hub propagates inventory events in under 8 m s to all connected clients. The AWS CI/CD pipeline—comprising Code Commit, Code Build, and Code Pipeline targeting Elastic Beanstalk—automates the full delivery lifecycle from code commit to production switchover. Comparative analysis across eight related systems demonstrates that the proposed platform is the only open-source solution concurrently offering real-time push notifications, multi-branch role segregation, zero-downtime deployment, and native cloud CI/CD integration. These contributions establish a reproducible architectural pattern for enterprises migrating legacy inventory systems to cloud-native paradigms, with documented extension paths toward horizontal scalability, demand forecasting, and federated identity management.
References
[1] M. C. Nah and H. C. Chang, \"Challenges in enterprise resource planning modernization: A systematic review,\" IEEE Access, vol. 11, pp. 34201–34218, 2023.
[2] P. Kroll and P. Kruchten, \"ERP systems deployment challenges,\" J. Syst. Soft w., vol. 195, p. 111531, 2023.
[3] C. Peng, M. Kim, Z. Zhang, and H. Lei, \"Multi-tenant SaaS database tenancy patterns,\" in Proc. IEEE Int. Conf. Cloud Compute. (CLOUD), 2022, pp. 45–53.
[4] S. Subramanian and R. L. Kumar, \"Supply chain visibility through real-time data platforms,\" Int. J. Prod. Econ., vol. 258, p. 108780, 2023.
[5] M. Fowler and J. Lewis, \"Microservices: A definition of this new architectural term,\" martinfowler.com, Mar. 2014. [Online]. Available: https://martinfowler.com/articles/microservices.html
[6] J. Humble and D. Farley, Continuous Delivery: Reliable Software Releases Through Build, Test, and Deployment Automation. Upper Saddle River, NJ: Addison-Wesley, 2010.
[7] M. Fowler, \"Blue Green Deployment,\" martinfowler.com, Mar. 2010. [Online]. Available: https://martinfowler.com/bliki/BlueGreenDeployment.html
[8] S. Ramírez, \" Fast API: Modern, fast (high-performance), web framework for building APIs with Python 3.6+ based on standard Python type hints,\" GitHub, 2023. [Online]. Available: https://github.com/tiangolo/fastapi
[9] Tech Empower, \"Web Framework Benchmarks, Round 22,\" 2024. [Online]. Available: https://www.techempower.com/benchmarks/
[10] M. Bayer, \"SQL Alchemy : The Database Toolkit for Python, version 2.0,\" SQL Alchemy Documentation, 2023.
[11] F. Patel and A. Singh, \"Scalable WebSocket architectures for real-time collaborative applications,\" IEEE Trans. Serv. Compute ., vol. 16, no. 4, pp. 2544–2557, 2023.
[12] T. Nguyen, L. Hoang, and P. Tran, \"Push-based inventory alerting in warehouse management systems,\" Compute . Ind. Eng., vol. 175, p. 108890, 2023.
[13] R. S. Sandhu et al., \"Role-based access control models,\" IEEE Compute ., vol. 29, no. 2, pp. 38–47, 1996.
[14] A. Ali and B. Khalid, \"Role-based access control in multi-branch inventory systems using Django,\" J. Soft. Eng. Appl., vol. 15, no. 8, pp. 312–329, 2022.
[15] R. Bhatt and D. Shah, \"Automated deployment pipelines using AWS Code Pipe line for Python microservices,\" in Proc. IEEE Int. Symp. Soft w. Reliab . Eng. (ISSRE), 2023, pp. 234–241.
[16] M. Bayer, \"Alembic: A database migrations tool for SQL Alchemy,\" GitHub, 2023. [Online]. Available: https://github.com/sqlalchemy/alembic
[17] R. Kumar and P. Jain, \"Comparative evaluation of open-source inventory management platforms,\" Procedia Compute. Sci., vol. 218, pp. 1540–1550, 2023.
[18] A. Osmani, \"The PRPL Pattern,\" Google Developers, 2023. [Online]. Available: https://developers.google.com/web/fundamentals/performance/prpl-pattern
[19] E. You, \"Vite: Next Generation Frontend Tooling,\" GitHub, 2024. [Online]. Available: https://github.com/vitejs/vite
[20] Amazon Web Services, \"AWS Well-Architected Framework,\" AWS Whitepaper, Nov. 2023. [Online]. Available
https://docs.aws.amazon.com/wellarchitected/latest/framework/welcome.html